#include "WPILib.h"
#include "PandroidSettings.h"
#ifndef MOTOR_WRAPPER
#define MOTOR_WRAPPER

class MotorWrapper : public PIDOutput {
public:
	typedef enum {speed = 0, position = 1,voltage = 2} MotorMode;
	MotorWrapper(UINT32 motorChannel, MotorMode mode, bool flip);
	virtual ~MotorWrapper();
	void SetEncoderCPP(int cpp);
	void Enable();
	void Disable();
	void SetSetpoint(float setpoint);
	void SetPID(float p, float i, float d);
	float GetP();
	float GetI();
	float GetD();
	float GetState();
	float GetSetpoint();
	virtual void PIDWrite(float output);
	float GetTemp();
	float GetVoltage();
private:
	CANJaguar *_motor;
	int _mode;
	float _setpoint;
	bool _reverse;
};

#endif
